#include <stdio.h>
#include <string.h>
void print(char arr[], int len)
{
    int i = 0;
    for (i = 0; i < len; i++)
    {
        printf("%c", arr[i]);
    }
}
void reverse(char arr[], int len)
{
    int left = 0; int right = len - 1; char p = 0;
    while (left < right)
    {
        p = arr[left];
        arr[left] = arr[right];
        arr[right] = p;
        left++;
        right--;
    }
}
int main()
{
    int len = 0;
    char arr[10001];
    gets(arr);
    len = strlen(arr);
    reverse(arr, len);
    print(arr, len);
    return 0;
}